package com.itwxz.forum.controller.mobile;

import cn.dev33.satoken.annotation.SaIgnore;
import cn.dev33.satoken.util.SaResult;
import com.itwxz.forum.domain.dto.UpdateForumUserDto;
import com.itwxz.forum.domain.po.ForumUser;
import com.itwxz.forum.service.ForumUserService;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@Slf4j
@Tag(name = "论坛用户信息Controller")
@RestController
@RequestMapping("/forum/mobile/user")
public class ForumUserMobileController {
	@Autowired
	private ForumUserService userService;

	@SaIgnore
	@PutMapping
	public SaResult updateForumUser(@RequestBody UpdateForumUserDto dto) {
		return SaResult.ok(userService.updateForumUser(dto));
	}
}
